package com.jianzhile.jobs.encrypt;


public class KEY {
	public static String privateKey = "MIICdgIBADANBgkqhkiG9w0BAQEFAASCAmAwggJcAgEAAoGBAL3noxkMsuEVdak1"
			+ "\r"
			+ "KOUSHT0KZbjY6IL6k3hMXCGEvEspTEnZBVA1s6DgSV8OolxTXcrnjp0HC1KeyILT"
			+ "\r"
			+ "jthtJ1n922IuVdnhrxkOVvhz6O8jNYGXCV5vdPwsMgq2c/FpsTQuHe4FEJ9DNxZA"
			+ "\r"
			+ "aWJaEsMaYZODCc9cMGlgTEK45Z1ZAgMBAAECgYAMzIzYhluUAf9BHT0ZW0QvNgEv"
			+ "\r"
			+ "GSdqlHrV88eN1sVeB3WF0KOkCUqHADbRuknFETVUFJEvEid4NQ1si9enzIuHTm4v"
			+ "\r"
			+ "n2f6qBBXh4bOkwaUFTVjnKXAbUtCiFFH/SfntniYvg05/VJjZ70L9jLt3wE2N91v"
			+ "\r"
			+ "IgREgniZCPlIRIVIgQJBAOYYnloG3Ot2XU+Ff56wAfW2pETGmps56GDmXe3FNYAL"
			+ "\r"
			+ "jgTCb4/UyrCyCFTNwlEQ4qcQvcoMhgM02tp6QlDJ+JECQQDTSLPbSVzSWISTvG1s"
			+ "\r"
			+ "xf1cPX+Z7wLxSSvQLMP/7C1QgR+LtrehbwXjHOvig8zl/vdICpcLRDJLpWbnhNh8"
			+ "\r"
			+ "L/xJAkAp+SWxwHy+Syo8XlroZK0G2JlgnmYHmOml+3/45reaswDmJ13Ye/W5g9B3"
			+ "\r"
			+ "P82Joi3mUex9FgnAPf0KS7EbMayxAkBaU7CgxUJrovA7AMl/QT3J23jb5HTLls6m"
			+ "\r"
			+ "Vx0MInpU+n70Cg+DcqV/rPOjiVll0pUBNZXReTxPXs0ZmY+7uAARAkEAg3rEMMzu"
			+ "\r"
			+ "jPken8j5jwuw9aIyJOfOQppWvGTzKOpAy0BaeZ+iTzfRrifPPFMhNELiXVtSodCo"
			+ "\r" + "VBgUZnjVvUbzAg==" + "\r";
	public static String publicKey = "MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQC956MZDLLhFXWpNSjlEh09CmW4"
			+ "\r"
			+ "2OiC+pN4TFwhhLxLKUxJ2QVQNbOg4ElfDqJcU13K546dBwtSnsiC047YbSdZ/dti"
			+ "\r"
			+ "LlXZ4a8ZDlb4c+jvIzWBlwleb3T8LDIKtnPxabE0Lh3uBRCfQzcWQGliWhLDGmGT"
			+ "\r" + "gwnPXDBpYExCuOWdWQIDAQAB" + "\r";
	// public static String privateKey = "";
	// public static String publicKey = "";
	//
	// /**
	// * 获取私钥别名等信息
	// */
	// public static void initKeyInfo(Context context) {
	// String privKeyPswdString = "1234567890abc";
	// String keyAlias = null;
	// try {
	// KeyStore keyStore = KeyStore.getInstance("PKCS12");
	// FileInputStream fileInputStream =
	// context.getResources().getAssets().openFd("private_key.p12")
	// .createInputStream();
	// char[] nPassword = null;
	// if ((privKeyPswdString == null) || privKeyPswdString.trim().equals("")) {
	// nPassword = null;
	// } else {
	// nPassword = privKeyPswdString.toCharArray();
	// }
	// keyStore.load(fileInputStream, nPassword);
	// fileInputStream.close();
	// Enumeration<String> enumeration = keyStore.aliases();
	// if (enumeration.hasMoreElements()) {
	// keyAlias = (String) enumeration.nextElement();
	// }
	// PrivateKey prikey = (PrivateKey) keyStore.getKey(keyAlias, nPassword);
	// Certificate cert = keyStore.getCertificate(keyAlias);
	// PublicKey pubkey = cert.getPublicKey();
	// publicKey = Base64.encodeToString(pubkey.getEncoded(), Base64.CRLF);
	// privateKey = Base64.encodeToString(prikey.getEncoded(), Base64.CRLF);
	// } catch (Exception e) {
	// System.out.println(e);
	// }
	// }
	//
	// /**
	// * 读取公钥cer
	// *
	// * @param path .cer文件的路径 如：c:/abc.cer
	// * @return base64后的公钥串
	// * @throws IOException
	// * @throws CertificateException
	// */
	// public static String getPublicKey(Context context) throws IOException,
	// CertificateException {
	// InputStream inStream =
	// context.getResources().getAssets().open("public_key.cer");
	// ByteArrayOutputStream out = new ByteArrayOutputStream();
	// int ch;
	// while ((ch = inStream.read()) != -1) {
	// out.write(ch);
	// }
	// inStream.close();
	// byte[] result = out.toByteArray();
	// return Base64.encodeToString(result, Base64.DEFAULT);
	// }
}
